home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 1 / Cream of the Crop 1.iso / EDUCATE / DIVECOMP.ARJ / DIVECOMP.TXT < prev    next >
Internet Message Format  |  1991-01-14  |  52KB

  1. Return-Path: <dans@hpnjld.hp.com>
  2. Date: Tue, 8 Jan 91 13:03:46 est
  3. From: Dan Schwartz <dans@hpnjld.hp.com>
  4. To: JJB0391@MARS.LERC.NASA.GOV, pbhyg!pacbell!rwmackl@PacBell.COM,
  5.         bomgard@iuvax.cs.indiana.edu, duis%bent.esd.sgi.com@SGI.COM,
  6.         eckhouse@ATHENA.MIT.EDU, gps@apple.com, gt0248c@prism.gatech.edu,
  7.         horst@tasman.cc.utas.edu.au,
  8.         ncr-sd!mtunion.SanDiego.NCR.COM!davem@hp-sdd.sdd.hp.com,
  9.         amdahl!kafka@hplabs, jagrogan@vax1.tcd.ie, jimsa@u.washington.edu,
  10.         mjs@hubcap.clemson.edu, ohara@brahms.AMD.COM, oivindt@ulrik.uio.no,
  11.         r31510k@kaira.hut.fi, rasmuse@mist.CS.ORST.EDU,
  12.         stephenf@softway.sw.oz.au, whipple@brahms.udel.edu, zeke@cdc.com
  13. Subject: Re: divecomp for DOS now available
  14.  
  15. The following shell archive contains an MSDOS EXE file which is a
  16. port of Dave Waller's divecomp program (version 2.5).  It was compiled
  17. with Microsoft Quick C 2.0, and uses the PC Curses library.
  18.  
  19. The program simulates the operation of a dive computer, and shows
  20. nitrogen loading in all of the compartments during the course of 
  21. simulated dives.
  22.  
  23. Anyone interested in the source code should consult rec.scuba, or the
  24. scubasearch archive, for Dave's original posting.
  25.  
  26. Dan Schwartz      dans@hpnjld.hp.com
  27. Hewlett-Packard, New Jersey Division
  28.  
  29. -------------------------------------------------------------------------------------------
  30.  * Revision 2.5  90/12/12  15:30:02  15:30:02  dave (Dave Waller)
  31.  
  32. Changes as of revision 2.5:
  33.  
  34. New features (lots!):
  35.  
  36. Now checks for "LINES" or "WIDTH" environment variable set, truncating the
  37. compartment bar graph appropriately (for those of you who simulate DEEP
  38. dives :-))
  39.  
  40. New option, -P, displays compartments as absolute pressure instead of
  41. tissue loading %age. The pressure is in <units> sea water absolute, where
  42. <units> is whatever units have been specified with the -u option. Default
  43. is feet. -P also causes the compartment values logged to an optional log
  44. file (specified with -l) to be in absolute pressure instead of loading
  45. %age.
  46.  
  47. Graph can be toggled between loading display and absolute pressure
  48. display by pressing the 't' key WHILE THE PROGRAM IS CALCULATING, not
  49. while it is wating for input. For example, if you are running interactive
  50. and you enter a depth of 100 ft for 20 minutes, 't' can be used while
  51. the 20 minutes are elapsing to toggle the screen. 't' does not affect
  52.  
  53. initial -P option.
  54.  
  55. Changed the transition depth between bottom time and surface interval
  56. counting to 3 feet from 5 feet. This was necessary for decompression
  57. stuff (more later).
  58.  
  59. 'q' can be pressed during calculations to abort the calculated run.
  60. For instance, when calculating a long decompression in autodecompression
  61. mode (more on this later), you can press 'q' to return to the input
  62. prompt. Similarly when calculating a long depth/duration combination
  63. entered from the keyboard.
  64.  
  65. No Decompression Limits are now displayed and continuously updated along
  66. side the dive profile for each depth displayed.
  67.  
  68. When NDLs are exceeded, the stats line now displays a ceiling, and a
  69. time to surface assuming proper following of the ceiling in 5 foot stops.
  70. For example, after 20 minutes at 200 feet, the stats line might display
  71. "Ceiling: 75.0 ft Time to surface: 46 min", indicating that the diver
  72. should not go shallower than 75 feet. If the diver makes decompression
  73. stops every 5 feet (stopping at each stop until the ceiling goes up to
  74. the next 5' stop), it will take 46 minutes to make it safely to the surface.
  75.  
  76. Depths deeper than the deepest depth in the dive profile display now
  77. show a 'v' in the deepest depth rather than not being displayed at all.
  78.  
  79. Bar graph now automatically reverts to a 2:1 scale in both loading and
  80. absolute display modes. For instance, if any compartment exceeds 100%
  81. loading, the graph will rescale to 0-200% (similarly for absolute
  82. pressure display).
  83.  
  84. Autodecompression: When NDLs have been exceeded, the diver can
  85. autodecompress by entering 'd' at the depth prompt. This will cause the
  86. program to advance to the nearest 5' deeper than the indocated ceiling,
  87. and follow the ceiling up in 5' increments. This will produce a profile
  88. exactly equal to that used in calculating the 'time to surface' value.
  89.  
  90. If available on your keyboard, the up and down arrow keys can now be
  91. used to change depth by one depth increment (as shown in the profile
  92. display) with each press during calculation. This is mainly useful while
  93. plotting a portion of a profile (i.e. 60' for 50 minutes), and you want
  94. to create a more realistic profile by moving up or down while
  95. calculating.
  96.  * 
  97.  * Revision 2.4  90/11/27  15:30:03  15:30:03  dave (Dave Waller)
  98.  * new features:
  99.  * 
  100.  * - tissue loading graph now compresses when tissue loading exceeds
  101.  *   100%, to a scale of 0-200%. Rescales to 0-100% when all compartments
  102.  *   are <= 100%.
  103.  * 
  104.  * - Compartments can now be displayed as absolute pressure in (units) sea
  105.  *   water, instead of % loading. Default is loading graph, absolute
  106.  *   pressure can be selected at runtime with -P option. While the program
  107.  *   is running, user can toggle between the two modes by typing 't' (this
  108.  *   only works while calculations are taking place, not while waiting for
  109.  *   input). Scale along the top is calibrated in (units) sea water absolute.
  110.  * 
  111.  * - During calculation, depth can be adjusted up or down using the up and
  112.  *   down arrow keys on the keyboard. For example, if the program is calculating
  113.  *   a dive level of 60 feet for 50 minutes, the depth can be adjusted up or
  114.  *   down by pressing the arrow keys. Adjustments are made in increments
  115.  *   equal to the depth increment in the dive profile display.
  116.  * 
  117.  * - If compartments are overloaded, the program can "autodecompress" by
  118.  *   entering a depth of 'd' in interactive mode. The program will then
  119.  *   move up to the ceiling value and "ride" it until all the compartments
  120.  *   are <=100% loading.
  121.  * 
  122.  * - When displaying compartment loading, pressure values are in (units) SWA
  123.  *   instead of FSWA. (Of course, if the units are feet, then the values
  124.  *   *are* FSWA).
  125.  * 
  126.  * - Stats line during overloading now displays a more meaningful message
  127.  *   regarding ceiling and decompression time.
  128.  * 
  129.  * Revision 2.1  90/11/21  11:33:57  11:33:57  dave (Dave Waller)
  130.  * Changed SUN ifdefs to be macro SIMPLE instead... Makefile has been
  131.  * modified as well. Since Sun users can now compile with full SVID
  132.  * curses functionality, it seemed unnecessary to remove the reverse
  133.  * video bells and whistles for for them. However, this functionality
  134.  * is retained as a "simple" version of the program for those that do not
  135.  * have reverse video and underline capabilities on their terminals.
  136.  * 
  137.  * Revision 2.0  90/11/21  11:11:30  11:11:30  dave (Dave Waller)
  138.  * Bug fixes:
  139.  * 
  140.  * - incompatible typecasting in several places made the program fail
  141.  *   with certain model files.
  142.  * 
  143.  * - Logical error in the sample period determination algorithm.
  144.  * 
  145.  * Enhancements:
  146.  * 
  147.  * - added capability to display depth in arbitrary units. Default is
  148.  *   feet. Units are specified in either a profile file on the first line
  149.  *   or with the -u option. To use a different unit system, the user must
  150.  *   supply the unit name and a unit conversion factor that represents
  151.  *   units/ft. For example, to display in fathoms, the user would type
  152.  * 
  153.  *   divecomp -mEdge -ufathoms:0.1667
  154.  * 
  155.  *   There are 6 feet in a fathom, or 1/6=0.1667 fathoms per foot. For meters,
  156.  *   the specification would be -umeters:0.3048, or -um:0.3, etc.
  157.  * 
  158.  *   The unit specification is written into an output profile, so that the
  159.  *   correct units are used when using the profile. Units specified in a
  160.  *   profile file override command line specification.
  161.  * 
  162.  * - added logging capability. A log file can be specified with the -l
  163.  *   option, and the program will write the allowed nitrogen %age for
  164.  *   each compartment at each sample period into the log file. A header
  165.  *   containing information regarding the model, sample period, and depth
  166.  *   unit used is initially written into the file before the simulation
  167.  *   begins. To make a log of a computer run, type
  168.  * 
  169.  *   divecomp -mBuhlman -umeters:0.3 -llog.buhlman
  170.  * 
  171.  * 
  172.  * Revision 1.9  90/11/20  11:24:48  11:24:48  dave (Dave Waller)
  173.  * Bug fixes:
  174.  *      - logical errors in reading sample period from specified sources
  175.  *      - update_dive_profile() routine hada rounding error in the
  176.  *        code that compresses the display.
  177.  * 
  178.  * Enhancements:
  179.  * 
  180.  *      - new profile file format. Profiles are now stored as depth-duration
  181.  *        pairs, instead of discrete samples. This eliminates the need for
  182.  *        sample period specification in the profile file, and makes the
  183.  *        file more compact and easier to read. I have written a filter
  184.  *        'cvtprof' to convert from the old format to the new format, so
  185.  *        any existing profiles that people have can be easily converted.
  186.  * 
  187.  *        Profiles created with the -o option in interactive mode are written
  188.  *        in the new format.
  189.  * 
  190.  * Revision 1.8  90/11/16  16:33:45  16:33:45  dave (Dave Waller)
  191.  * Cleaned up rounding algorithm for depth profile; added round up to
  192.  * compartment bar graph display, so that it reads 100% properly;
  193.  * Fixed scale graphic at top of compartment bar graph (it was off
  194.  * by one character position to the right, contributing tothe bars not
  195.  * being at 100% visually when they actually were).
  196.  * 
  197.  * Revision 1.7  90/11/16  10:34:26  10:34:26  dave (Dave Waller)
  198.  * Added ability to specify different sample periods. Sample period ('s' in
  199.  * the source) is specified in the following manner (decreasing precedence):
  200.  * 
  201.  *            1) via command line option
  202.  *               Example: divecomp -mEdge -omyprof -s2.5
  203.  * 
  204.  *               Units are in minutes
  205.  * 
  206.  *            2) From within a profile file. The first line can optionally
  207.  *               specifiy a sample rate, if it has the form "s:<rate>".
  208.  *               Example: A profile that contains 2 minute samples would
  209.  *               look like
  210.  * 
  211.  *               s:2.0
  212.  *               60
  213.  *               60
  214.  *               60
  215.  *               60
  216.  *               .
  217.  *               .
  218.  *               .
  219.  * 
  220.  *               (the ellipses [...] are not part of the file). 'divecomp'
  221.  *               now automatically writes the sample period into every profile
  222.  *               it generates via the -o option.
  223.  * 
  224.  *             3) From a model file. Format is the same as a profile file.
  225.  *                The most basic command, "divecomp -mEdge", for instance,
  226.  *                will cause the computer to use the proper sampling rate
  227.  *                for the Edge. Also, any profiles generates with this model
  228.  *                will have the correct sampling value when used in different
  229.  *                models.
  230.  * 
  231.  *             4) Default: 1 minute.
  232.  * 
  233.  * Revision 1.6  90/11/14  17:36:52  17:36:52  dave (Dave Waller)
  234.  * Added compile time checks to modify curses behavior to accomodate
  235.  * incomplete curses library on Sun/OS. Controlling tissue is highlighted
  236.  * with a preceding '*' instead of reverse video, deiling message does not
  237.  * appear in reverse video when tissue M values are exceeded, and tissue
  238.  * bar graph is composed of '#' characters instead of reverse video
  239.  * spaces. Not quite as pretty as the full curses version, but that's what
  240.  * you get if you're running on a Sun.
  241.  * 
  242.  * Original graphical functionality is maintained for other platforms.
  243.  * 
  244.  * Revision 1.5  90/11/14  13:58:43  13:58:43  dave (Dave Waller)
  245.  * Added the following features:
  246.  * 
  247.  * - Decompression calculation and indication via ndl()
  248.  * - ingas/outgas indicator nxt to each compartment number
  249.  * - full "bottom timer" functions (i.e. dive #, bottom time, surface int)
  250.  * 
  251.  * Fixed the following bugs:
  252.  * 
  253.  * - would run forever if duration of 0 entered in interactive mode.
  254.  *   Program now rejects such an entry, and asks for depth and duration
  255.  *   again.
  256.  * 
  257.  * - Controlling tissue indication lagged one sample behind actual value;
  258.  *   Fixed.
  259.  * 
  260.  * - Dive profile graph now rounds up to the nearest depth increment.
  261.  * 
  262.  * Revision 1.4  90/11/13  16:38:49  16:38:49  dave (Dave Waller)
  263.  * Fixed up the comments.
  264.  * 
  265.  * Revision 1.3  90/11/13  15:11:48  15:11:48  dave (Dave Waller)
  266.  * Initial checkin; started using RCS to keep track of revisions. This
  267.  * revision also fixes a bug with the code that reads in half times from model
  268.  * files -- they were stored as type 'int', which created problems for
  269.  * fscanf if the half times were floats. Changed the array 'half[]' to
  270.  * type 'float'.
  271.  *  */
  272.  
  273. /* dive computer simulator, by Dave Waller (davew@hpdstma.hp.com)
  274.  
  275. =============================================================Acknowlegments:
  276.  
  277. Much thanks to Eric Williams (sargon@portia.stanford.edu) for his
  278. outstanding contribution to the ndl() routine to incorporate ceilings
  279. and decompression times.  His support and timely reviews/bug reports
  280. have been extremely helpful.  Thanks, Eric!
  281. ============================================================
  282.  
  283. This program simulates a multi-compartment model dive computer, based
  284. upon modified Haldanean tissue absoption models.  The number of
  285. compartments and their corresponding constants are not built into the
  286. program, but must be loaded at runtime, allowing the program to
  287. simulate most dive computers on the market today.
  288.  
  289. Subsequent derivation of equations as found in the comments below were
  290. done by myself, as I sit here at work, using only my memory;
  291. therefore, this initial pass at the simulation may contain some errors
  292. that I will have to fix later, after I have had time to review the
  293. pertinent material at home.  Surprisingly enough, it seems to work
  294. pretty accurately, based upon my experience with my ORCA Delpi.  Have
  295. fun!
  296.  
  297.        Tissue halftimes in general express the time it takes for a
  298.        tissue to either absorb or release nitrogen such that the
  299.        tissue is 50% equalized to the pressure differential between
  300.        the ambient nitrogen pressure and the tissue nitrogen
  301.        pressure. This uptake or outgassing obeys an asymptotic
  302.        exponential, namely if ambient pressure is PA, and initial tissue
  303.        pressure is PT0, then the tissue pressure as a function of
  304.        time is expressed as,
  305.  
  306.        PT = PT0 + (PA - PT0)(1 - e^(-kt))
  307.  
  308.        where k = -ln(0.5)/T     = 0.6931/T
  309.                     half           half
  310.  
  311.        This formula holds true for static conditions; i.e. PA does
  312.        not change. In reality, a diver will probably be continuously
  313.        changing depth, and therefore PA is changing also. A
  314.        reasonable approximation of continous PT values can be
  315.        calculated by sampling PA at discrete intervals, and applying
  316.        the above formula over the preceding sample interval, then
  317.        starting over with a new PA and PT0 for the next interval
  318.        based upon the calculation.
  319.  
  320.        In this simulated computer, we assume datapoints are recorded
  321.        one per minute. Since the halftimes are expressed in minutes,
  322.        the above formula can be reduce to an adjustment at each
  323.        sample that consists of the following:
  324.  
  325.        PTnew = PTlast + K(PA - PTlast)
  326.  
  327.        where K = (1 - e^(-k*1)) = 1-e^(-k) = 1 - (1/e^k) =
  328.  
  329.                    1 - (0.5)^(1/T    )
  330.                          half
  331.        
  332.        Note that the K value is dependant upon consistency between
  333.        the units of the compartment half time and the computer
  334.        sample period. Specifically, the above formula only applies
  335.        if the sample period is 1 unit of the half time unit (in this
  336.        case minutes). For an arbitrary sample period s, the formula
  337.        for the K value is
  338.  
  339.        K = 1 - (0.5)^(s/T    )
  340.                  half
  341.  
  342.        The dive computer simulator calculates the K values on
  343.        startup, with the sample period 's' being taken from the
  344.        following sources, in order of decreasing priority:
  345.  
  346.        1) a sample period specified on the command line with the
  347.           -s option
  348.  
  349.        2) A sample period specified in a profile file. This must
  350.           take precedence over a sample period in a model file,
  351.           otherwise the number of samples in the file will not
  352.           match the dive profile in real time. In order to compare
  353.           different models, the same sampling period must be used
  354.           for a single profile.
  355.  
  356.        3) A sample period specified in the model file
  357.  
  358.        4) The default sample period of 1 second
  359.  
  360.        */
  361.  
  362. ----------------------------------------------------------------------------------------------------
  363. From: davew@hp-ptp.HP.COM (Dave_Waller)
  364. Newsgroups: rec.scuba
  365. Subject: Dive computer program is here!
  366. Date: 10 Nov 90 01:41:02 GMT
  367. Organization: HP Pacific Technology Park - Sunnyvale, Ca.
  368.  
  369. Okay, folks, you asked for it. Here is my first pass at a divecomputer
  370. program that I hacked together during lunch. As far as I can tell, it
  371. seems to be working pretty accurately, based upon my experience with the
  372. Delphi (although this version uses half-times and M-values as posted for
  373. the Edge by Eric Williams).
  374.  
  375. The first response to this posting is a shell archive that contains 3
  376. files: "divecomp.c", "makefile", and "data".
  377.  
  378. To build your dive computer, unwrap the shar file as specified in its
  379. instructions, and type "make divecomp". This should wourk on just about
  380. any UNIX system, as the program is really rather simple.
  381.  
  382. The file "data" contains made-up data for a simgle multi-level dive. All
  383. it is a set of depth values, one minute apart. The program assumes that
  384. depth is sampled every minute.
  385.  
  386. The program uses the 'curses' library, so you must have a terminal
  387. cabable of supporting cursor addressing and reverse video. Current
  388. features at this early quick-hack release are:
  389.  
  390.     * A continuously updated bar graph of all 12 tissue saturations
  391.       (relative to M values), with the actual N2 tissue partial
  392.       pressure displayed in FSW at the end of each bar. If a tissue
  393.       exceeds 100% of the allowable nitrogen, the bar changes to
  394.       asterisks.
  395.  
  396.     * Continuous display of depth.
  397.  
  398.     * Continuous display of bottom time, and surface interval (after
  399.       the dive).
  400.  
  401.     * A continuously updated graph of the dive profile.
  402.  
  403. To see all of this, you need a display with about 50 lines; X-window
  404. terminal emulators work pretty well. If you have only a 24 line
  405. terminal, you'll have to comment out the dive profile display so it
  406. doesn't (potentially) mess up the tissue graph.
  407.  
  408. Please post any questions/problems as followups to this note. I'll try
  409. to get to them as quickly as I can, and it would be helpful for anyone
  410. else having problems. Have fun!
  411.  
  412. Tomorrow: A list of planned enhancements!
  413.  
  414. Dave Waller  \  The opinions expressed are solely my own, and in no way
  415. Hewlett-Packard Co.  \  represent those of my employer (but we all know
  416. dave@hpdstma.ptp.hp.com | hplabs!hpdstma!dave  \  they should!)
  417.  
  418.  
  419.  
  420.  
  421. From: davew@hp-ptp.HP.COM (Dave_Waller)
  422. Newsgroups: rec.scuba
  423. Subject: Latest version of divecomputer program
  424. Date: 13 Nov 90 18:06:49 GMT
  425. Organization: HP Pacific Technology Park - Sunnyvale, Ca.
  426.  
  427. Here is the latest version, which is MUCH improved over the version you
  428. were running. As we all bug fixes, it incorporates many new features:
  429.  
  430.     -mmodel        specifies the file "model" as the file
  431.             containing half-time Mvalue pairs. Must be
  432.             specified.
  433.  
  434.     -pprofile    Specifies a file containing a dive profile,
  435.             in one minute samples. If not specified, the
  436.             program is in interactive mode, allowing the
  437.             user to specify depths and durations.
  438.  
  439.     -ooutfile    Optional output filename to record interactively
  440.             entered dive profile. Useful for saving profiles
  441.             to be used for comparison between different
  442.             computers using different model files.
  443.  
  444.     Computer now computes and displays NDL, and highlights the
  445.     controlling tissue.
  446.  
  447.     Adapts to different screen sizes automagically now. Looks for
  448.     environment variable "LINES", and if not found, assumes 24.
  449.  
  450. So, I have included the new version with this message, along with the
  451. Edge and Navy model files, and a sample profile. Check it out and let me
  452. know what you think.
  453.  
  454.  
  455. Dave Waller  \  The opinions expressed are solely my own, and in no way
  456. Hewlett-Packard Co.  \  represent those of my employer (but we all know
  457. dave@hpdstma.ptp.hp.com | hplabs!hpdstma!dave  \  they should!)
  458.  
  459.  
  460. --------------------------------------------------------------------
  461. From: sargon@portia.Stanford.EDU (Eric Williams)
  462. Newsgroups: rec.scuba
  463. Subject: Discussion of Decompression Models (long)
  464. Keywords: decompression, models, history, M values, dive computer
  465. Date: 15 Nov 90 02:02:38 GMT
  466. Organization: AIR, Stanford University
  467.  
  468. Those of you who asked for this stuff, sorry I left you hanging.
  469. It just took me a while.  This is a discussion about decompression models.
  470. It starts with history, then gets into math, and finally specifics
  471. about things like diving at altitude.  (It's a *really* long message.
  472. You may want to save it and read it in pieces.)
  473.  
  474.  
  475. I.  A Little History of Decompression Models.
  476.  
  477. Our knowledge of DCS (decompression sickness) goes back over three
  478. hundred years to 1670 when Robert Boyle described his observations of 
  479. animals in lowered pressure environments.  In the 1800's that
  480. knowledge expanded with the frequent use of caissons and other
  481. pressurized work environments.  The first human cases of DCS were
  482. reported in 1841 in coal miners working in mines pressurized to keep
  483. out water.  In 1857, Hoppe-Seyler suggested that DCS was caused by
  484. bubbles in the tissues and suggested treatment by recompression.
  485. In 1878, Bert discovered that it is nitrogen that is responsible for
  486. DCS.
  487.  
  488. The British Navy commissioned J. S. Haldane to investigate the causes
  489. of DCS and to propose a solution.  In the early 1900's by working on
  490. goats, he made several observations which still influence our thinking
  491. on DCS today.  His procedure was to bring the goats to a higher than
  492. atmospheric pressure and leave them there for "a while"--I think it
  493. was about 4 hours [EW].  Then he would lower the pressure and look for
  494. DCS.  (Animal rights activists, where were you then?  :-)
  495.  
  496. He reported that saturated tissues could be decompressed to one half
  497. their pressure without the onset of DCS, e.g. from 2 atm to 1 atm.
  498. Bringing a tissue back from more than 2 atm could be done in stages,
  499. allowing time for the tissue to resaturate to the new pressure at each
  500. stage, e.g. from 4 atm to 2 atm then waiting, and then from 2 atm to 
  501. 1 atm.
  502.  
  503. Haldane developed a model of compression and decompression which is 
  504. still used today as the basis of many decompression models.  The
  505. Haldanean model can by summariezed by the following prinicples:
  506.  
  507. + Absorbtion and elimination of nitrogen by the body is at an
  508.     expontential rate.  That is, the rate at which a tissue
  509.     takes in or releases gases is proportional to the pressure
  510.     difference between the tissue and the surroundings (see
  511.     math section)
  512.  
  513. + There is a continuous spectrum of tissue types in the body with 
  514.     various rates of absorbtion and elimination.
  515.  
  516. + The rate of absorbtion is the same as the rate of elimination for
  517.     any given tissue group.
  518.  
  519. + The continuous spectrum of tissue types in the body can be
  520.     approximated by a finite number of groups from within the
  521.     range.
  522.  
  523. In 1908, the Royal Navy adopted the tables that Haldane developed using
  524. his model.  In 1915 the US Navy published its first set of tables (the 
  525. C & R tables).
  526.  
  527. In the 1930's Hwkins, Shilling and Hansen (and later Yarborough)
  528. determined that the allowable supersaturation is not a constant
  529. two as Haldane had said, but depends on the tissue half time and
  530. the depths and duration of the dive.  In 1937, Yarborough made
  531. tables for the US Navy based on a model that had three tissue
  532. compartments with half times of 20 minutes, 40 minutes and 75
  533. minutes respectively.
  534.  
  535. In 1957, the US Navy tables were corrected and improved and the
  536. repetitive dive tables were added.  The tables were based on six
  537. compartments with half times of 5, 10, 20, 40, 80, and 120
  538. minutes.  The concept of "M-values" originiated with these tables.
  539. "M-values" specify the maximum supersaturation a compartment can
  540. withstand without getting bent.  The M values were modelled as
  541. a constant plus an increment proportion to depth (M = M0 + dM*D).
  542.  
  543. In 1976, the Pennsylvania Analysis of Decompression from Undersea
  544. and Aerospace (PADUA) model was introduced.  It consisted of 10
  545. compartments, with half times all the way up 480 minutes.  More
  546. conservative M0 and delta-M values were used.  Although the model
  547. is more conservative than the US Navy model, no tables have been
  548. produced for publication.
  549.  
  550. Also in 1976, Spencer made his famous Doppler Ultrasound measurements
  551. looking for venous gas emboli (VGE -- fancy name for bubbles in the
  552. blood).  If bubbles were the cause of DCS then why not look for bubbles
  553. directly.  He found that at the Navy's no decompression limits there
  554. were already significant numbers of VGE present in the blood.  He
  555. suggested reduced limits which virtually eliminated the presence of 
  556. VGE upon surfacing.
  557.  
  558. In 1981, Huggins published new repetitive dive tables based on a model
  559. similar to the US Navy's, but with M0 values based on the new no
  560. decompression times from Spencer.  Furthermore, the tables considered
  561. all 6 compartments in assigning repetitive groups, not just the 120
  562. minute group as the US Navy did.  The tables had no provision for
  563. decompression.
  564.  
  565. In 1983, Buhlmann developed another model for decompression (also
  566. called the Swiss model).  It is still based on Haldane's assumptions
  567. and on tissue compartments, but uses a different specification of 
  568. maximum compartment pressure that takes into account the ambient
  569. pressure at the surface.  (Other tables assume 1 atm.)  They are unique 
  570. in that from the outset they were developed to be used at altitude
  571. in Swiss lakes.  This also makes the tables useful for determining
  572. the safety of flying after diving, due to reduced pressure in the
  573. airplane cabin.
  574.  
  575. In 1984, Thalmann at the Navy Experimental Diving Unit (NEDU) reported
  576. on an algorithm that the Navy had been developing for use in a closed-
  577. circuit mixed gas system.  The algorithm is called E-L (as opposed to
  578. E-E in the usual) because the compartment in-gassing occurs at an 
  579. exponential rate just as in the Haldanean models, but the outgassing
  580. occurs at a slower, linear rate.
  581.  
  582. In 1985, two new models were proposed, both based on novel new
  583. approaches.  At the University of Hawaii, the Varying Permeability
  584. Model was proposed.  It attempts to model the number and size of 
  585. gas bubbles in the blood, and bases the ascent criteria on the
  586. total volume of bubbles in the body.
  587.  
  588. At the Naval Medical Research Institute (NMRI) a statistical
  589. approach to DCS was developed, called the Maximum Likelihood
  590. Statistical Method.  Using a database of over 1700 individual
  591. exposures, model parameters were determined, and then several
  592. tables were developed associating sets of no-decompression times
  593. with various likelihoods of DCS (e.g. 1% or 5%, etc.)
  594.  
  595. [I'm sure there is more out there, and probably more recent findings
  596. but this is what my research a year ago turned up. --EW]
  597.  
  598.  
  599. PROBLEMS
  600.  
  601. The problem with all of these is that they are only models.  Factors
  602. such as temperature, individual characteristics, exertion level, 
  603. ascent rate and more complicated effects of bottom time are all
  604. known to influence susceptibility to DCS, but none are included in 
  605. the models.  Attempts to model bubble formation rather than just
  606. tissue saturation are IMHO a step in the right direction.  But as
  607. someone pointed out a while ago on the net, there isn't even a 
  608. great correlation between observed bubbles and DCS!
  609.  
  610. A classic example where the models break down is bounce diving.
  611. A recipe for DCS:  Something like 50% (vague recollection giving
  612. ballpark magnitude) of divers following this profile get bent:
  613. Doing everything by the book (e.g. proper ascent rate) dive to a 
  614. relatively deep depth ( > 60 ft) for a short time then return to
  615. the surface.  Repeat a few times with a short surface interval
  616. in between dives.
  617.  
  618. For the Haldanean models there is no fundamental difference between
  619. this and regular dive profiles.  Tissues in-gas then out-gas, and if 
  620. the times are right you won't go over their limits.  But the incidence
  621. of DCS says bounce diving defintely does something funny to your body.
  622.  
  623. One theory I've heard is that on a first dive (even relatively benign
  624. ones) microscopic bubbles are formed.  Since it's easier for bubbles
  625. to grow than to form in the first place, on subsequent dives they can
  626. get much worse.  The bounce diving just multiplies this.
  627.  
  628. I believe the rational behind the safety stop is to try to get rid of 
  629. most of these bubbles (they go away better under pressure), or maybe
  630. to prevent their formation in the first place.  I'm not really sure.
  631. The point is the Haldanean models don't really take any of this into
  632. account.
  633.  
  634. The moral is:  Safety stops (especially) and longer surface intervals
  635. (somewhat) are good things!  :-)  Never trust your dive computer
  636. completely.  It's only a model and the models have limitations.
  637.  
  638. NOTE that because of these problems with the model and the general
  639. feeling that the model is _only_ a model, people tend to use the
  640. term 'compartment' rather than 'tissue' when talking about Haldanean
  641. models in order to highlight that the mathematical model may have
  642. no physical connection to actual tissues in the body.  I sometimes
  643. accidentally use the two interchangably (as does the literature)
  644. but the tendency is towards using 'compartment'.  So if I should
  645. slip and say tissue where I mean compartment, you'll know what i mean.
  646.  
  647.  
  648.  
  649. SOME NOTES ABOUT THE EXPONENTIAL MODEL
  650.  
  651. The number that characterizes how quickly a compartment takes in or
  652. releases pressure is called the HALF-TIME.  It is analogous to a half-
  653. life in radiation.  It is defined as the time it takes for the pressure
  654. to drop (or rise) from its initial value HALFWAY to ambient pressure.
  655. In theory it would take an infinite amount of time to actually get to
  656. ambient pressure (because as you get closer it slows down).  But in
  657. practice a few half-times is all that's needed (after 3.5 half times
  658. you're at 90% and after six half times you're at 98.4%).  Six half-
  659. times is generally considered to be saturation.
  660.  
  661. ASIDE:  The 12 hour time after diving before you're considered to be
  662. "clean" comes from this.  The US Navy tables had a 120 minute slowest
  663. compartment, so after 6*2 hours all of your compartments would be
  664. back to normal surface pressure.  Current thinking is that this isn't
  665. long enough when you do extensive diving over a long period or before
  666. going to altitude (e.g. flying).  Thus they incorporate slower compartments
  667. to give the model more "memory."
  668.  
  669.  
  670. II.  The Math
  671.  
  672. Go back and look at the basis of the Haldanean model.  That's where this
  673. picks up.  (Dave Waller (dave@hpdstma.ptp.hp.com) gives much of this in
  674. the openning comments of the dive computer program.)
  675.  
  676. The change in a compartment's pressure is proportional to the difference
  677. between the compartment's current pressure and ambient pressure.  
  678. Translation:
  679.  
  680.     dP = k * (PA - P) * dt        where P is compartment pressure
  681.                       and PA is ambient pressure
  682.  
  683. Solving this and using the initial condition P = PT0 at t=0 gives the
  684. following (math in between deleted :-)
  685.  
  686.     P = PT0 + (PA - PT0)*(1 - e^(-kt))
  687.  
  688. If you want to do an iterative computation to keep track of the
  689. compartment pressures, the computation is what you would expect:
  690.  
  691.     P_new = P_old + (PA - P_old)*(1 - e^(-kt))
  692.  
  693. Where do we get k?  Well, we have another condition.  We know that
  694. at t=HALF-TIME, (1 - e^(-kt)) = 0.5 by definition.  Thus:
  695.  
  696.     k = ln(2) / HALF-TIME
  697.  
  698.  
  699. M-VALUES
  700.  
  701. So we know how to model the compartments now.  How do we know when
  702. they are at their limits, etc?
  703.  
  704. The models specify M-values which are the maximum compartment pressures
  705. for which it is still safe to return to the surface (assuming 1 atm at
  706. the surface).  More concisely M-values are the maximum absolute PARTIAL 
  707. PRESSURE of nitrogen measured in feet of seawater (FSW).  (Absolute,
  708. meaning that 0 is a total vacuum.)
  709.  
  710. In numbers, at sea level (1 atm =~= 33 fsw) the partial pressure of
  711. nitrogen is 0.79 * 33 = 26 fsw.  The US Navy table uses an M-value of
  712. 104 fsw for the 5 minute compartment.  Thus for returning to the
  713. surface a 4:1 supersaturation is permissible without [symptoms of]
  714. DCS.  
  715.  
  716. [ASIDE: IMHO, It's not exactly clear when to say DCS actually begins.
  717. Damage caused by small bubbles could be so minor as to be asymptomatic]
  718.  
  719. Note that since M-values are given the the nitrogen partial pressure
  720. you would want to do the calculations of compartment pressures with
  721. just the nitrogen.  i.e.  PA is ambient nitrogen partial pressure.
  722. The program calls this apn2.  At depth (D >= 0)
  723.  
  724.     apn2 = (D + P0) * 0.79        where D is depth
  725.                           P0 is surface ambient pressure
  726.                         (usually 33 fsw)
  727.  
  728.  
  729. NO DECOMPRESSION TIME REMAINING
  730.  
  731. So you want to compute how much time you have left at a given depth
  732. before you're compartments saturate.  Just solve the P equation for t
  733. given the pressures.
  734.  
  735. Let T = time to reach saturation
  736.     M = the M-value
  737.     C = current compartment pressure
  738.     A = ambient pressure (at depth)
  739.  
  740. Then
  741.  
  742.     M = C + (A - C)*(1-e^(-kT))
  743.  
  744. Solving for T:
  745.  
  746.     T = (1/k) * ln((A - C) / (A - M))
  747.  
  748. or in terms of half-time, H:
  749.  
  750.     T = H * log-base-2 ((A - C) / (A - M))
  751.  
  752. Note that using the properties of logarithms you can manipulate the
  753. equation around a bit, but the form is the same.
  754.  
  755. Also note that the solution of this equation is dependent on there
  756. being a solution!  The three variables A, C and M have six possible
  757. relations (e.g. A > C > M, etc)  Only two of these have meaningful
  758. solutions, but all of them give you some information about the
  759. compartment.
  760.  
  761. They are:
  762.  
  763. A > M > C    The compartment is still below its limit (what I might call
  764.         normal, as opposed to being in a decompression mode,
  765.         M > C) but is eventually going to exceed its limit
  766.         because A > M and A > C.  The equation _does_ have a 
  767.         meaningful solution for T, it's the no decompresion
  768.         time remaining.
  769.  
  770. M > A > C    The compartment is 'normal' (M > C) and furthermore it
  771.         is what I might call 'safe' i.e. (M > A) so not only
  772.         is it not over the limit, it will never go over the
  773.         limit at this ambient pressure.  (A > C) so the
  774.         compartment is in-gassing (increasing in pressure).
  775.         Since it is 'safe' the T equation has no solution.
  776.         You can say T = +INFINITY for this compartment.
  777.  
  778. M > C > A    The compartment is 'normal' (M > C).  It is 'safe' (M > A)
  779.         it is outgassing (decreasing in pressure) (C > A).  
  780.         Again, T = +INFINITY.
  781.  
  782. A > C > M    The compartment is over is limit (C > M), so it's no
  783.         longer safe to return to the surface.  Your dive computer
  784.         would be in 'decompression mode' now, if it had one.
  785.         Furthermore it is still in-gassing (A > C).  At this
  786.         ambient pressure the compartment will never get back below
  787.         its limit (A > M).
  788.  
  789.         In a decompression mode, the no decompression limit no
  790.         longer has meaning, but might like to know how long it
  791.         take before we're out of decompression.  I'll call this
  792.         TDC.
  793.  
  794.         For this condition, TDC = +INFINITY
  795.  
  796. C > A > M    The compartment is in a decompression mode (C > M).
  797.         It is out-gassing (C > A) but it will still never get
  798.         back below the limit because (A > M).  TDC = +INFINITY
  799.  
  800. C > M > A    The compartment is in a decompression mode (C > M).
  801.         It is out-gassing (C > A) and will eventually get back
  802.         to a safe state.  The equation for T also solves for
  803.         this condition.  Look at the LOG(stuff) to convince
  804.         yourself that it will return a positive, finite solution
  805.         that _is_ what we are looking for.  Thus, TDC = equation
  806.         gives to time left to decompress.
  807.  
  808.  
  809. Interesting relations to note are: 
  810.  
  811.     (C > M)   over/under M-value limit
  812.     (C > A)   out/in gassing
  813.     (M > A)   'safe' vs 'unsafe'**
  814.  
  815. ** This term I coined myself for lack of a better mneumonic.  I call it
  816. safe because in 'normal' mode a 'safe' compartment will never go over 
  817. its M-value.  In decompression mode, when the compartment is already
  818. over its M-value, only a 'safe' one will eventually get back back below
  819. the limit.
  820.  
  821.  
  822. THE REAL COMPUTATION
  823.  
  824. The above discussion only covers a single compartment.  The overall
  825. state of the model is a composite of the state of the individual
  826. compartments.
  827.  
  828. - If any compartment is in decompression, then it will dominate over
  829.     compartments that are not (i.e. are 'normal').
  830.  
  831. - Among 'normal' compartments the one with the lowest NDL is the
  832.     controlling compartment.
  833.  
  834. - Among 'decompressing' compartments the one with the highest TDC
  835.     is the controlling compartment.
  836.  
  837.  
  838. Note that it can be very tough to give an absolutely correct answer
  839. for TDC, because you can have a mixture of compartments some over-
  840. saturated (in decompression) and some under the limit but still 
  841. in-gassing.  
  842.  
  843. At a particular depth, you might be counting down the minutes for
  844. one compartment to get back below the limit and mean while another
  845. one goes over.  Granted it's slightly pathalogical, but definitely
  846. _can_ happen.
  847.  
  848.  
  849. CEILING
  850.  
  851. Given that you have decided you are in a decompression mode and
  852. can't go up to the surface, what depth _is_ safe?  The smallest
  853. depth (shallowest) you can ascend to when in a decompression mode
  854. is called your ceiling.
  855.  
  856. To compute this we need to know how M changes with depth.  We may
  857. be over the M-value for the surface, but at some depth we'll be
  858. o.k.
  859.  
  860. The original Haldanean principles just specified a ratio that is 
  861. safe.  e.g. 3:1 (compartment to ambient) is the limit.  You could
  862. use this to figure out what your ceiling.
  863.  
  864. For some reason (maybe this way works better, less DCS, maybe someone
  865. was just lazy, I dunno) this isn't the way most model do it.  Dating
  866. back to 1957 and the US Navy tables, the following method is used:
  867.  
  868.     M_at_depth = M_at_surface + delta-M * depth
  869. or 
  870.     M = M0 + dM * depth
  871.  
  872. (the 'd' of dM is actually supposed to be the capital greek letter 
  873. 'delta', but the net doesn't seem to support greek!  :-)
  874.  
  875. Each compartment has an M0 and dM value.  Frankly, I'm not sure exactly
  876. how the dM's were derived for the Navy Model.  The ORCA Edge model just
  877. sets them all [somewhat arbitrarily --EW] to 1.0 (which is less than
  878. the Navy values and therefore more conservative).
  879.  
  880. For a particular compartment, the ceiling is simply:
  881.  
  882.     ceiling = (C - M0) / dM
  883.  
  884. where C = compartment pressure
  885.       M0 = what I used to call M, max pressure allowed at surface
  886.       dM = the incremental change in M with depth
  887.  
  888. To compute the composite ceiling for the whole model, just take
  889. the worst case (deepest ceiling).
  890.  
  891.  
  892. STAGED-DECOMPRESSION
  893.  
  894. In order to decompress you must be at an ambient pressure that's
  895. lower than the compartment value (so that you out-gas) and yet
  896. deeper than your ceiling.  This can lead to staged decompression
  897. for some situations.
  898.  
  899. Note that the slow compartments also have lower M-values.  If you've
  900. gone way over on your faster tissues and slightly over on your slow
  901. tissues, you would have to do a staged-decompression.
  902.  
  903. The ceiling would be determined by the fact that you were way over
  904. on the faster tissues.  But at the depth specified by the ceiling,
  905. the slower tissues may not be outgassing, since ambient pressure
  906. could be greater than the compartment pressure.  
  907.  
  908. As you waited below your ceiling, the fast compartment would
  909. outgas and the ceiling would slowly move up.  You could then move
  910. up to a shallower depth.  You would repeat this until you were at
  911. a depth sufficiently shallow for the slower tissues to outgas.
  912.  
  913. This should give you an idea of why it's hard to compute the
  914. actual TDC (time to decompress).  In addition, while you were stuck
  915. at the deeper ceiling, other slow tissues with low M-values could
  916. be in-gassing and could go over the limit.
  917.  
  918. In order to give the right number from the start you would have to
  919. consider all these possibilities.
  920.  
  921.  
  922. III.  Other neat stuff, like adjusting for altitude
  923.  
  924. When you dive at altitude the surface ambient pressure is lower
  925. than normal (something like 2/3 atm at 10,000 ft is what I remember
  926. hearing).  In order for the tissues to see the same oversaturation
  927. *ratio* which is what we believe to be the controlling factor, you
  928. must reduce the M values.
  929.  
  930. For example, the Navy 5 minute compartment M0 of 104 fsw gives a
  931. 4:1 supersaturation ratio (104 / (33*0.79)).  If we went to 10,000 ft
  932. (assuming my 2/3 atm number is right) the same 104 fsw would give
  933. a ratio of 6:1.  Some compensation must be done.
  934.  
  935. ASIDE:  This is also relevant to flying after diving.  Since the
  936. compartment of commercial jet-liners is typically kept at 8,000 ft
  937. what your dive computer says is o.k. to do at sea level could
  938. cause problems if you immediately hopped on a plane for home.
  939. In fact this make air-evacuation after a diving accident a little
  940. tricky (and expensive !!!).
  941.  
  942. The question is how to do the compensation.  I don't have a solid
  943. answer for this, but we can still think about it.
  944.  
  945. The obvious way to handle it is to scale the M-values to preserve
  946. the same supersaturation ratios that you had on the surface.  e.g.
  947. in the previous case 104 fsw would scale to 69.3 fsw (104 * 2/3).
  948. IMHO this is a very reasonable way to do it.
  949.  
  950. The only model that I have info on that was designed to handle
  951. altitude is the Buhlmann model.  This model specified the maximum
  952. pressures a little differently than the M-value model started by
  953. the US Navy.  In this model:
  954.  
  955.     Pmax = a + Pamb/b
  956.  
  957. instead of:
  958.  
  959.     M = M0 + dM * depth
  960.  
  961. where 'a' and 'b' are the constants for the compartment.  Pamb is the
  962. absolute pressure at depth (e.g. 0 is a vacuum).  Thus it includes both
  963. depth and surface pressure together.  Pmax is the same as M -- the
  964. maximum pressure that a compartment can have without problem.
  965.  
  966. The two models are equivalent with a little manipulation:
  967.  
  968.     Pamb = P0 + P_depth
  969.  
  970. if you use fsw as your unit of pressure, then P_depth is just the depth.
  971. Thus:
  972.  
  973.     Pmax = (a + P0/b) + (P_depth) * (1/b)
  974.  
  975. If you convert the units of 'a' to fsw (b is unitless) then:
  976.  
  977.     M0 = a' + P0/b
  978.     dM = 1/b
  979.  
  980. where P0 is ambient pressure at the surface.
  981.  
  982. The Buhlmann model was designed for and has been tested at altitude
  983. in Swiss lakes.  Therefore, we should also consider this approach to
  984. altitude compensation.  
  985.  
  986. In the first model (straight ratios) if the pressure dropped by 1/3
  987. then 1/3 of the M0 was subtracted.  In the Buhlmann model only a
  988. fraction of the pressure drop is subtracted, with the actual
  989. fraction depending on the a's, b's and surface pressure.
  990.  
  991. In practice, the fraction varies from 35% for the fastest compartments
  992. to 80% for the slowest (with most compartments above 60%).  Thus we
  993. might subtract only 35% of the 1/3 of the normal M0.
  994.  
  995. Unfortunately I don't know how they decided on the a's and b's which
  996. determine this.  Since I don't have good information on how these
  997. numbers came about it's hard to adapt this to other models.
  998.  
  999. Does anyone out there know how dive computer X compensates for
  1000. altitude?  Some I know of use the Buhlmann model.  The Delphi is
  1001. one I'm curious about because I'd bet Orca used their same Edge
  1002. model but scaled the values somehow.
  1003.  
  1004. [Is anyone out there still reading at this monster of a posting!! :-)]
  1005.  
  1006.  
  1007.  
  1008. REFERENCES
  1009.  
  1010. <see my previous post about M-values for various models.>
  1011.  
  1012. The pointer to the original Buhlmann paper is in the
  1013. Proceedings of the AAUS Dive Computer Workshop, 1989.  
  1014.  
  1015. A coulple of people asked me for more info on how to get the
  1016. publications I cited.  (The American Academy of Underwater
  1017. Sciences and Michigan Sea Grant Publications).
  1018.  
  1019. I gave out the addresses on an individual basis, but I figured 
  1020. I should wait until I had contacted them to find out their policy/
  1021. price/scoop before posting to the net-at-large.
  1022.  
  1023. If you want the addresses, mail me and I'll send them out as long
  1024. as the volume isn't overwhelming.  If you can wait a bit, I just 
  1025. dashed off a couple of letters to them explaining what I want and
  1026. will post to the net when I get a response.
  1027.  
  1028.  
  1029. --Eric Williams. sargon@portia.stanford.edu
  1030.  
  1031. P.S.  If you haven't already done so, try out the dive computer
  1032. program it's really neat!  (and helps you get a feel for how all
  1033. this works)
  1034.  
  1035. --------------------------------------------------------------------
  1036.  
  1037. From: sargon@portia.Stanford.EDU (Eric Williams)
  1038. Newsgroups: rec.scuba
  1039. Subject: Re: Feature Request: Let's design our own dive computer
  1040. Summary: decompression, m-values, dive computer
  1041. Date: 8 Nov 90 21:42:43 GMT
  1042. Organization: AIR, Stanford University
  1043.  
  1044. (This is a little late, I tried posting yesterday, but had problems)
  1045.  
  1046. About a year ago I did a comparison report of different dive computer
  1047. models for my Open Water I course.  A dive computer was (and still is)
  1048. on my project list, so I've been following this discussion with
  1049. interest.
  1050.  
  1051. I've got values for four different models, including the Navy.  They've
  1052. been transcribed about three different times (source to notes to report to
  1053. here) so if you have any of these, please compare, I could have garbled them.
  1054.  
  1055. First, the numbers, then some references on decompression models.  Some
  1056. discussion about M values and delta M's should probably accompany this,
  1057. but I'll assume we're all on the same wavelength and save it for 
  1058. another posting.  (The M values are most important, the delta M's are
  1059. only used in decompression algorithms.)
  1060.  
  1061. ============
  1062. US NAVY
  1063.  
  1064. T 1/2    M0    dM
  1065. (min)    (fsw)    (--)
  1066. ------    -----    -----
  1067. 5    104    2.27
  1068. 10    88    2.00
  1069. 20    72    1.71
  1070. 40    58    1.40
  1071. 80    52    1.29
  1072. 120    51    1.27
  1073.  
  1074. << Sanity check: Do we all still agree?  Everybody should have the
  1075.    same numbers here. >>
  1076.  
  1077. <<< Now that this is late, I've checked this against duis@sgi and they
  1078.     agree.  I don't think there are other compartments in the Navy model.
  1079.     (Like 180, 240, etc.) >>>
  1080. =============
  1081. Huggins Model.  These numbers were derived and used by Karl Huggins
  1082.   to generate the no-bubbles tables.
  1083.  
  1084. T 1/2    M0    dM
  1085. (min)    (fsw)    (--)
  1086. -----    -----    -----
  1087. 5    102.0    0
  1088. 10    85.0    0
  1089. 20    67.5    0
  1090. 40    54.5    0
  1091. 80    47.5    0
  1092. 120    43.0    0
  1093.  
  1094. << There are no dM values for this model because it is not intended to
  1095.    be used as for decompression. >>
  1096.  
  1097. =================
  1098. ORCA Edge (and Skinny Dipper, I think)  Also by Huggins
  1099.   These were published in 1987.  There are no guarantees
  1100.   that these are the numbers actually used, or that they
  1101.   haven't been tweaked slightly.
  1102.  
  1103. T 1/2    M0    dM
  1104. (min)    (fsw)    (--)
  1105. -----    -----    -----
  1106. 5    100.0    1.0
  1107. 11    81.8    1.0
  1108. 17    71.5    1.0
  1109. 24    63.7    1.0
  1110. 37    55.9    1.0
  1111. 61    50.7    1.0
  1112. 87    46.8    1.0
  1113. 125    43.0    1.0
  1114. 197    39.1    1.0
  1115. 271    36.5    1.0
  1116. 392    33.9    1.0
  1117. 480    33.0    1.0
  1118.  
  1119. << These are from the Sea Grant publication by Huggins, see references >>
  1120.  
  1121. =========================
  1122. Buhlman (Swiss) Model.  Some explanation is in order here.  The
  1123.   Buhlman model was developed in Switzerland and (I think) been
  1124.   tested at alititude in Swiss lakes.  It is based on a different
  1125.   calculation of maximum compartment pressure than the M value one
  1126.   (Pmax = a + Pamb/b, Pamb is absolute ambient pressure (in Pascals!)
  1127.   where a and b are the numbers specified for each compartment.)
  1128.  
  1129.   It was my observation, (I've never seen this in print)
  1130.   that it was equivalent to the M value calculation (M = M0 + dM*D)
  1131.   with a little manipulation and units conversion:
  1132.         M0 = a + P0/b, dM = 1/b, 'a' must be converted to fsw, 
  1133.         b is unitless, P0 is air pressure at the surface.
  1134.  
  1135.   The following are my calculations of what M values would be for
  1136.   this model.  Unfortunately, I've don't seem to have the original
  1137.   a's and b's around, but they're in the references.
  1138.  
  1139. T 1/2    M0    dM
  1140. (min)    (fsw)    (--)
  1141. -----    -----    -----
  1142. 2.65    114    1.22
  1143. 7.94    91    1.22
  1144. 12.2    77    1.21
  1145. 18.5    70    1.20
  1146. 26.5    65    1.18
  1147. 37    58    1.16
  1148. 53    54    1.15
  1149. 79    53    1.12
  1150. 114    53    1.12
  1151. 146    51    1.07
  1152. 185    51    1.07
  1153. 238    48    1.06
  1154. 304    43    1.04
  1155. 397    43    1.04
  1156. 503    43    1.04
  1157. 635    43    1.04
  1158.  
  1159. << Again, note that these are unchecked and unpublished. >>
  1160.  
  1161. ==================================
  1162.  
  1163. REFERENCES
  1164.  
  1165. Edmunds, Carl, "Dive Computers -- The Australian Experience"
  1166.     Proceedings of the AAUS Dive Computer Workshop, AAUS
  1167.     Costa Mesa, CA, USCSG-TR-01-89, 1989, pp. 59-68.
  1168.  
  1169. Egstrom, Glen H., "Dive Computers, Dive Tables and Decompression"
  1170.     same as above, pp. 163-168.
  1171.  
  1172. Huggins, Karl E., Micropressor Applications of Multi-Level Air
  1173.     Decompression Problems.  Michigan Sea Grant Program,
  1174.     NA86AA-D-SG043, 1987.
  1175.  
  1176. Lewis, John E., "The Datamaster II -- A Fundamentally Different
  1177.     Dive Computer," Proceedings ... AAUS... 1989, pp. 43-47.
  1178.  
  1179. Loyst, Ken and Michael Steidley, Diving with Dive Computers,
  1180.     Watersport Publishing, San Diego, 1989.
  1181.  
  1182. Somers, Lee H. "Dive Computers in Scientific Diving Programs"
  1183.     Proceedings ... AAUS...1989, pp. 203-205.
  1184.  
  1185. Short, Donald R. and C. Mark Flahan, "Reconstructing the Navy
  1186.     Tables," Proceedings .. AAUS ... 1989, pp. 181 - 187.
  1187.  
  1188.  
  1189. Unfortunately, I don't have any of these references myself.  I
  1190. borrowed them from my instructor.
  1191.  
  1192. Let's keep this discussion going.  I think it's very interesting.
  1193. I'd be happy to port another article with background on M values
  1194. and compartments and how they're used to compute, no decompression
  1195. time remaining and decompression ceiling, etc. etc.
  1196.  
  1197. --Eric Williams. sargon@portia.stanford.edu, uucp? thru decwrl?
  1198.  
  1199.  
  1200. ------------------------------------------------------------------
  1201. From: duis@sgi.com (David Duis)
  1202. Newsgroups: rec.scuba
  1203. Subject: Re: Feature Request: Let's design our own dive computer
  1204. Summary: Extended Navy M-values table
  1205. Keywords: dive computers, algorithms, features, US Navy Tables, M values
  1206. Date: 9 Nov 90 01:32:23 GMT
  1207. Reply-To: duis@bent.esd.sgi.com
  1208. Organization: Silicon Graphics, Inc., Mountain View, CA
  1209.  
  1210. In article <1990Nov7.225018.23403@odin.corp.sgi.com> duis@sgi.com (David Duis) writes:
  1211. >As promised, here are the US Navy M-values, as used to compute the
  1212. >current Navy tables.  
  1213. >
  1214. >These figures represent the maximum allowable no-decompression
  1215. >nitrogen-loading.  Figures for the 160, 200, and 240 minute
  1216. >compartments are not listed in the NAUI book -- I'll look them up in
  1217. >_Physiology & Medicine of Diving_ RSN (Real Soon Now :-).
  1218.  
  1219. As promised, here is the extended table.  Please note that the
  1220. 160,200, and 240 minute compartments are used only for the Navy
  1221. Exceptional Exposure tables.  However, I consider a multi-day
  1222. multi-dive-per-day dive trip to be an "exceptional exposure," thus I
  1223. have included these values.
  1224.  
  1225.  
  1226.     Compartment         Surfacing ratios:
  1227.     Half time      TOTAL   NITROGEN  M-VALUE (fsw)
  1228.         5             4:1    3.15:1     104
  1229.        10          3.4:1    2.67:1      88
  1230.        20          2.75:1    2.18:1      72
  1231.        40         2.22:1    1.76:1      58
  1232.        80            2:1    1.58:1      52
  1233.       120         1.96:1    1.55:1      51
  1234.       160         1.96:1    1.55:1      51
  1235.       200           1.96:1    1.55:1      51
  1236.       240         1.92:1    1.52:1      50
  1237.  
  1238.  
  1239. I look forward to ANY simulation, now that we have these values.
  1240. While it would be nice to model every computer, a simple multi-level
  1241. simulation of the Navy Tables would be nice.  
  1242.  
  1243. Anyone have the M-values for the DSAT table, which uses a 60-minute
  1244. controlling half-time?  I believe these are the same values as those
  1245. used in the Sherwood Source/Oceanic Sport, so we'd be doubly served.
  1246.  
  1247.  
  1248. Cheers,
  1249.  
  1250. Dave Duis                             NAUI AI Z9588, PADI DM 43922
  1251. duis@bent.esd.sgi.com      opinions my own, and subject to dispute
  1252.  
  1253. --------------------------------------------------------------------
  1254.  
  1255.  
  1256.